<div class="newspost">
    <div class="header">
        <h1><?php echo $newspost->title; ?></h1>
    </div>
    <div class="postInfomation">
        <p><?php echo "Posted at: " . $newspost->posttime ." By :".$newspost->user->username; ?></p>
    </div>
    <div class="newspostbody"><?php echo $newspost->body; ?></div>
    <div class="tag">
    <?php foreach($tags as $tagObj): ?>
        <span>
            <a href="<?php PrintURL("newsposts", "search",$tagObj->tag) ?>">
                <?php echo $tagObj->tag; ?>
            </a>
        </span>
    <?php endforeach; ?>
    </div>
</div>